<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>mini Vue</title>
</head>
<body>
    <div id="app">
        <h1>插值表达式</h1>
        <h3>{{ message }}</h3>
        <h3>{{count}}</h3>
        <h1>v-text:</h1>
        <div v-text="message"></div>
        <input type="text" v-model="message">
        <input type="text" v-model="count">
        <h1>v-html:</h1>
        <div v-html="htmlContent"></div>

        <h1>v-on:</h1>
        <div v-on:click="handleClick" id="btn">点击</div>
        <input type="text" v-on:change="changeName">
    </div>
    <script src="./dep.js"></script>
    <script src="./Watcher.js"></script>
    <script src="./compiler.js"></script>
    <script src="./observer.js"></script>
    <script src="./vue.js"></script>
    <script>
        let vm = new Vue({
           el: '#app',
           data: {
               message: 'vue',
               count: 1,
               htmlContent: `<p style="color:pink">测试html内容</p><p>`
           },
           methods: {
            handleClick() {
                   console.log('点击');
               },
            changeName() {
                console.log('change事件改变');
            }
           }
       })
    </script>
</body>
</html>